package fr.isima.myant;

public class EchoTask extends Task {
	private String message;

	public EchoTask() {}
	
	public EchoTask(String message) {
		super();
		this.message = message;
	}
	
	public void setMessage(String message) {
		this.message = message;
	}
	
	@Override
	public String toString() {
		StringBuilder sb = new StringBuilder();
		
		sb.append("\t\tName : EchoTask");
		sb.append("\t\tMessage : " + message);
		sb.append("\n");
		
		return sb.toString();
	}
	
	@Override
	public void execute() {
		System.out.println(message);
	}
}
